#ifndef _BIT_SHIFTER_H_
#define _BIT_SHIFTER_H_

#include "../bit/bit.h"

enum BitShifterDirection
{	
	ShiftRight,
	ShiftLeft
};

class BitShifter
{
	private:
		//sets the direction to shift the value
		unsigned char direction;
		//the value that is shifted.
		unsigned char value;
	public :
		//default constructor.
		BitShifter();
		//constructor that sets the direction
		BitShifter(unsigned char direction);
		//sets the value of value to v.
		void set(unsigned char v);
		//gets the value in the shifter
		unsigned char get();
		//shifts in the bit bit passed in 
		void shiftIn(unsigned char bit);
		//shifts out a bit from the value and returns it.
		unsigned char shiftOut();
		//indexes the bits for easy access.
		unsigned char operator[](unsigned char index);


};

#endif


